package orest.back.membermanage;

import java.sql.Connection;
import java.sql.SQLException;

import net.ssta.common.Constants;
import net.ssta.core.db.DBConnectionProvider;
import net.ssta.core.db.DataBaseExecutor;
import net.ssta.core.db.PagingInfo;
import net.ssta.core.db.Record;
import net.ssta.core.db.RecordSet;

public class UnitUserSql {
	
	/**
	 * 根据机构id获取机构成果信息
	 * @param unitid
	 * @return
	 */
	public static String getArchieveByUnitid(String unitid){
		StringBuffer sql=new StringBuffer();
		
		sql.append(" SELECT * ");
		sql.append(" FROM T_UNIT U,T_KJCG A WHERE 1=1 ");
		sql.append(" AND U.UNITID=A.UNITID ");
		sql.append(" AND U.UNITID='").append(unitid).append("'");
		
    	return sql.toString();
	}
	
	/**
	 * 根据成果id获取成果详细信息
	 * @param unitid
	 * @return
	 */
	public static String getArchieveInfoById(String achieveid){
		StringBuffer sql=new StringBuffer();
		
		sql.append(" SELECT * ");
		sql.append(" FROM T_KJCG A WHERE 1=1 ");
		sql.append(" AND A.KJCGID='").append(achieveid).append("'");
		
    	return sql.toString();
	}
}
